//
//  RUMapViewController.m
//  runtorun
//
//  Created by KIMI on 16/10/21.
//  Copyright © 2016年 KIMI. All rights reserved.
//

#import "RUMapViewController.h"
#import <MAMapKit/MAMapKit.h>
@interface RUMapViewController ()

@end

@implementation RUMapViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    //实例化高德地图
    [self setupMapView];
}
- (void)setupMapView {
    
    //实例化高德地图
    MAMapView *mapView = [[MAMapView alloc]initWithFrame:[UIScreen mainScreen].bounds];
    //隐藏比例尺
    mapView.showsScale = NO;
    //罗盘
//    mapView.showsCompass = NO;
    //关闭相机旋转  降低能耗 省电
    mapView.rotateCameraEnabled = NO;
    
    mapView.showsUserLocation = YES;
    
    mapView.userTrackingMode = MAUserTrackingModeFollow;
    
    [self.view addSubview:mapView];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
